package com.ruoyi.pet.service.impl;

import java.util.List;

import com.ruoyi.pet.mapper.PetAppointmentMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.pet.domain.PetAppointment;
import com.ruoyi.pet.service.IPetAppointmentService;

/**
 * 预约挂号Service业务层处理
 * 
 * @author 木有枝
 * @date 2025-04-13
 */
@Service
public class PetAppointmentServiceImpl implements IPetAppointmentService 
{
    @Autowired
    private PetAppointmentMapper petAppointmentMapper;

    /**
     * 查询预约挂号
     * 
     * @param appointmentId 预约挂号主键
     * @return 预约挂号
     */
    @Override
    public PetAppointment selectPetAppointmentByAppointmentId(Long appointmentId)
    {
        return petAppointmentMapper.selectPetAppointmentByAppointmentId(appointmentId);
    }

    /**
     * 查询预约挂号列表
     * 
     * @param petAppointment 预约挂号
     * @return 预约挂号
     */
    @Override
    public List<PetAppointment> selectPetAppointmentList(PetAppointment petAppointment)
    {
        return petAppointmentMapper.selectPetAppointmentList(petAppointment);
    }

    /**
     * 新增预约挂号
     * 
     * @param petAppointment 预约挂号
     * @return 结果
     */
    @Override
    public int insertPetAppointment(PetAppointment petAppointment)
    {
        return petAppointmentMapper.insertPetAppointment(petAppointment);
    }

    /**
     * 修改预约挂号
     * 
     * @param petAppointment 预约挂号
     * @return 结果
     */
    @Override
    public int updatePetAppointment(PetAppointment petAppointment)
    {
        return petAppointmentMapper.updatePetAppointment(petAppointment);
    }

    /**
     * 批量删除预约挂号
     * 
     * @param appointmentIds 需要删除的预约挂号主键
     * @return 结果
     */
    @Override
    public int deletePetAppointmentByAppointmentIds(Long[] appointmentIds)
    {
        return petAppointmentMapper.deletePetAppointmentByAppointmentIds(appointmentIds);
    }

    /**
     * 删除预约挂号信息
     * 
     * @param appointmentId 预约挂号主键
     * @return 结果
     */
    @Override
    public int deletePetAppointmentByAppointmentId(Long appointmentId)
    {
        return petAppointmentMapper.deletePetAppointmentByAppointmentId(appointmentId);
    }
}
